package com.love.poetry.interfaces;

import javax.servlet.http.HttpServletRequest;

import org.springframework.stereotype.Controller;
import org.springframework.ui.Model;
import org.springframework.web.bind.annotation.RequestMapping;

@Controller
public class ExceptionErrorController {
	
	private static final String REDIRECT_EXCP = "error/500" ;
    private static final String REDIRECT_NO = "error/404" ;

    @RequestMapping (value = "/errorServer" )
    public String errorServer(Model model, HttpServletRequest request) {
                return REDIRECT_EXCP ;
   }

    @RequestMapping (value = "/errorNull" )
    public String errorNull404(Model model, HttpServletRequest request) {
                return REDIRECT_NO ;
   }

}
